Skip to content

fork fleet: desk seed fetch round-5 nits (#258) - #729

Merged
scuttletoby merged 3 commits into
mainfrom
fix/258-desk-seed-nits
Nov 21, 2026
Merged

scuttletoby merged 3 commits into
mainfrom
fix/258-desk-seed-nits

Conversation

@scuttletoby

@scuttletoby scuttletoby commented Nov 21, 2026 •

Copy link
Copy Markdown
Owner

Follow-ups from the round-5 lenses on #237 (desk seed fetch): security lens237sr5 and correctness lens237cr5. All four items in #258 are fixed in code, docs, or both.

What and why

  1. Doc line: a fix can wait for the step (item 1, cr5 nit 1 / sr5 nit 1). The script header, the TornLog docstring, fork-fleet.md and the desk README now say that a fix made right after another new copy waits for the end of the step, up to 24 h. This trade-off is intended.
  2. An early try no longer restarts the wait (item 2, cr5 nit 2). Root fix, not just a doc line. An early try (a new copy on the host during a back-off wait) still counts, so the next wait still doubles. It now keeps last, so the wait runs from the last try that waited, not from the early try. So an early try moves the next normal try at most one step later (h 5, not h 3, after an early try at h 1.5), and not at all at the 24 h cap. Before, each early try also restarted the wait from itself. The log line after a torn fetch gives the real time left (TornLog.due), not 2^(tries-1) from now. An hourly broken remake now gets tries at h 0, 1, 2, 5, 6 (before: 0, 1, 2, 6, 7). The test that pins this schedule is updated.
  3. Sparse handlers (item 3, sr5 nit 2).
    • Info now refuses every _proc_gnusparse_* that this Python's tarfile.TarInfo has, found by name at import. Before, only 00, 01 and 10 were listed by hand, so a later tarfile's new handler would not be overridden.
    • This goes past the lens suggestion: each run reads small probe tars with Tar/Info (sparse_read): one pax sparse tar of each form (0.0, 0.1, 1.0), an old-GNU sparse member, and a header over HEADER_MOST. The last two prove tarfile still calls Info._proc_member. Each probe must be torn by its own refusal. Anything else (read as a sparse member, read whole, torn by another limit, a tarfile error, or the probe cannot even be made) is named, and the run fetches nothing and exits 2, like a missing PRIVATE part (check shows it). Seeds past their age are still dropped.
  4. Quiet end of unpack (item 4, sr5 nit 3).
    • Info.fromtarfile lets only EOFHeaderError (a block of zeros) end the tar. Any other header error now tears the seed: a bad checksum, a pax size<0, a stream that ends with no end blocks, or a bad header as the last block. Before, TarFile.next() ended the tar quietly at any of these after the first header, and a short seed was swapped in.
    • After the end, the rest of the stream is read through tarfile's own buffer (t.fileobj), and only zero bytes are accepted. These bytes still count toward the trailer's size and SHA-256. Normal end blocks and record padding pass.

Not changed: the host-down-for-good row (cr4 2, documented in #237) is not part of #258.

State question

  • Runs again: an early try keeps last and sets early, so a second new copy in the same step waits until the step ends. Tested: test_an_early_try_keeps_the_wait_running_from_the_last_try_that_waited (also: at the 24 h cap an early try moves nothing).
  • Stopped half-way: .torn.json is saved before the fetch. The test reads it inside the fetch, which is what a run killed there leaves: last unchanged, tries + 1, early true. The next run waits for the step that was already running.
  • Old state: a record fork fleet: a desktop fetches its desk pool's seeds (D11b) #237 wrote, where an early try moved last, is read as it is. It waits from that last and is tried once the step ends (test_an_old_record_whose_early_try_moved_last_still_waits). A record without early, or without copy, behaves as before.
  • Empty or missing: no record means no wait, as before. An empty stream, or one with no end blocks, is torn; before, it was a ReadError or a quiet end. A tar of only end blocks still unpacks as an empty seed.

Tests

.github/scripts/fork-fleet-desk-seed.test.py: 7 new tests, plus the hourly-remake test now expects h 0, 1, 2, 5, 6 and checks the hours in the log line. 77 tests, OK on Linux, Python 3.12 (CI's) and 3.13.5.

  • On the old script (origin/main), on Linux Python 3.12, the first 6 new and changed tests give 9 failures and 2 errors (the earlier count, 7 and 2, was from macOS and counted only 5 of the 7 tar-end subtests):
    • the early-try schedule
    • the hourly schedule
    • all 7 subtests of the tar end
    • sparse_read missing
    • _proc_gnusparse_11 not overridden
  • test_an_old_record_whose_early_try_moved_last_still_waits passes on both. It checks old state, not a change.
  • Local runs are macOS, Python 3.14. This file is Linux-only: the same 5 tests fail on origin/main and on this branch (a hard link, a symlink over a folder, path length, RSS), and no other test fails. CI runs it on Linux.
  • Also run locally: fork-gate-trust-docs.test.py (86 OK) and fork-owned-reads.test.py (4 OK). fork-fleet-desk.test.py and fork-kit/desk/tests/install.test.py are Linux-only; they fail the same way on origin/main on macOS, and CI runs them.
  • node .github/scripts/fork-seam-check.cjs --config-ref origin/main origin/main HEAD: passes. Only fork files change.

Spot-checks: each fix line was removed alone, and its test went red:

  • last kept on an early try -> test_an_early_try_never_moves_the_next_try_later
  • the log line's hours from due -> test_a_host_that_remakes_each_hour_never_meets_the_back_off
  • override every _proc_gnusparse_* (back to the 3 fixed names) -> test_a_sparse_form_a_later_tarfile_adds_is_refused_too
  • sparse_read in run -> test_a_python_that_reads_a_sparse_member_past_info_fetches_nothing (all 3 forms)
  • only a probe's own refusal counts (refusal not in str(e) removed) -> test_only_its_own_refusal_proves_a_probe
  • fromtarfile turning header errors into Torn -> test_only_a_block_of_zeros_ends_the_tar_and_only_zeros_follow. The bad-header-as-last-block and no-end-blocks cases are caught only by this line; the bad checksum followed by more members is also caught by the zeros check.
  • only zeros after the end -> the same test (bytes after the end blocks, bytes after the padding)

Review round (lens A and B on 9660496, both SAFE)

Fixed in d666cd6:

  • Lens B major, lens A minor 4: the five doc lines that said an early try never moves the end of the wait now say what the code does (the wait doubles from the last try that waited, so the next normal try comes at most one step later, not at all at the 24 h cap). The test is renamed to test_an_early_try_keeps_the_wait_running_from_the_last_try_that_waited.
  • Lens B minor 2, lens A minor 2: the probe tar is made inside the try. A tarfile that cannot write it now gives exit 2 and still drops seeds past their age (test_a_probe_that_cannot_be_made_still_drops_an_old_seed_and_is_exit_2; on the old script: a raw ValueError, exit 1).
  • Lens B minor 3, lens A minor 1: only the probe's own refusal counts as refused. Another Torn, a tarfile error, or a member read whole is named and fails closed (test_only_its_own_refusal_proves_a_probe; fails on the old script).
  • Lens A minor 3: two new probes, an old-GNU S member and a header over HEADER_MOST, prove tarfile still calls Info._proc_member (same test, _proc_member case).
  • Lens B minor 4: the failure count above.
  • Also: the tar-end test now accepts Python 3.13.5's message for a pax size of -1 (the seed was already kept; only the message differed).

Left: lens A's note that a host can reset the back-off by leaving a seed out of its list for one run. #237 documents it, and the host already decides what the seed holds, so it is not part of #258. On Python 3.13.5, test_a_link_named_with_a_slash_over_a_file_is_refused (an older test this PR does not touch) fails on its message only; CI runs 3.12.

General vs project

General. This changes how the desktop reads any seed tar and paces retries. No project's seed names, sizes or makers are involved. Only fork files change: .github/scripts/fork-fleet-desk-seed*, .github/fork-fleet.md, fork-kit/desk/README.md.

Closes #258

🤖 Generated with Claude Code

- An early try (a new copy on the host during a back-off wait) keeps `last`:
  it still counts, but never moves the end of the wait; the log line says
  the real time left.
- Every `_proc_gnusparse_*` handler of this Python's tarfile is refused, and
  each run reads a small sparse tar of each pax form (0.0, 0.1, 1.0) to prove
  tarfile still reaches the refusal; if not, it fetches nothing (exit 2).
- Only a block of zeros ends the tar (any other bad header tears the seed),
  and only zeros may follow it, read through tarfile's own buffer.
- Docs: a fix made right after another new copy waits for the step (up to
  24 h); the early-try rule; the tar end; the sparse check.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@scuttletoby

Copy link
Copy Markdown
Owner Author

Review lens A (untrusted tar), head 9660496: SAFE

Read-only review. I read #258, #237's design, and this PR's script, docs and tests. I also ran my own crafted tars through Summed/Tar/Info/unpack/settle and the zeros-after loop from fetch, on Python 3.12.3 (Ubuntu, with the dircheck backports) and 3.13.5. CI is green on this head: fork-fleet-desk-seed.test.py ran 75 tests, OK; fork-kit/desk/tests/install.test.py passed too. I did not run the suite locally because the host's capacity check said NOT OK, so CI's Linux run is the evidence for it.

Blocking: none.
Major: none.

What I tried (all torn or harmless on both Pythons)

  • End of tar: no end blocks, a header cut part-way, a bad checksum after the first member, a pax header followed straight by a zero block, an empty stream, one zero block followed by junk, end blocks followed by another member, and bytes after the record padding were all torn. Normal end blocks plus extra zero padding, a single end block, and a tar of only end blocks were accepted, as they should be.
  • A header split across the buffer: the stream was fed one byte per read. The result was the same as a normal read, because _Stream builds up whole blocks first.
  • Sizes: a pax size=-1 (torn by fromtarfile on 3.12.3, by guarded on 3.13.5) and a pax GNU.sparse.realsize=-5 were torn. A realsize bigger than the header size failed with a ReadError.
  • Sparse: pax 0.0, 0.1 and 1.0, as the first member or a later one, and old-GNU S were all refused. sparse_read() returns [] on both Pythons.
  • Paths, links, devices: absolute paths stay inside data (the data filter strips the leading /). .. in the name or the pax path, an absolute symlink, a hard link to a later member, char devices and FIFOs were refused. An over-long GNU long name failed with an OSError, which counts as torn.
  • Huge member, or endless zeros after the end: bounded by Summed's max_mb and by FETCH_WAIT. The zeros loop reads PIECE bytes at a time.

Can a crafted seed get the retry schedule to fetch more often, or stop a fix being retried?

No new route. trying keeps last only when left() is not None. due allows only one early try per step, and the wait is still capped at 24 h. A clock set backward is still "try now" and resets last. A step can never end later than 24 h after the last try that waited.

Minor

  1. sparse_read counts any TarError as refused (.github/scripts/fork-fleet-desk-seed.py:431). A later tarfile that throws a TarError on the probe tar for some unrelated reason, while it still reads real sparse members through a handler with a new name, would pass the check. That needs two unlikely changes at once. One fix: whenever _proc_gnusparse_* names exist on tarfile.TarInfo, require a Torn for each form, and treat any other error as not proven, so the run exits 2.
  2. The probe's write step is outside its try block (:420-426, called at :658). If a later tarfile refuses to write the GNU.sparse.* pax keywords, run() raises before age_out and prune. The result is a traceback and exit 1, not the documented "drop seeds past their age, then exit 2". This still fails closed for fetching. Moving the write inside the try (and counting a failure there as a form that was read) keeps the documented path.
  3. The probe proves the sparse handlers are still called, but not _proc_member. The old-GNU S refusal (:395), HEADER_MOST and the size<0 guard all depend on tarfile still calling obj._proc_member. The pax probe would still pass if a later tarfile stopped calling it. This is the same kind of gap as sr5 nit 2. A cheap fix: add an S-type member and an extended header over HEADER_MOST to the per-run probe.
  4. Doc wording. The module docstring (:43, "never moves the step's end"), the TornLog docstring (:717, "never moves the next try later"), .github/fork-fleet.md:924 and fork-kit/desk/README.md:94 all say an early try never moves the end. It does move it later through the doubling: in test_an_early_try_never_moves_the_next_try_later the step ends at h 3 before the early try at h 1.5 and at h 5 after it. What the fix really does is not restart the wait from the early try. Suggested wording: "it never restarts the wait from the early try (the wait still runs from the last try that waited, and doubles)".

Note (not part of this PR)

A host can still reset the back-off by leaving the seed out of its list for one run (TornLog.keep, :732) or by offering none (torn.fine, :832). Either one also resets first, so late() never fires. A hostile host could then fetch a bad copy about every 2 h, each up to max_mb. #237 documented this ("only seeds in the host's list are kept"), and the host already decides what the seed contains, so it does not block this PR.

State question

  • Runs again: an early try keeps last, and only one early try is allowed per step.
  • Stops half-way: .torn.json is saved before the fetch, and a run killed during the fetch counts as torn. A copy cut off part-way is torn by the empty or truncated header check.
  • Old record: read as it is, and it waits from the last it already has.
  • Empty stream: torn. A tar of only end blocks still unpacks as an empty seed.

@scuttletoby

Copy link
Copy Markdown
Owner Author

Lens B (state and tests) on 9660496: SAFE

No blocking findings. One major doc finding: the docs promise a retry timing the code does not have. It is a wording fix, not a safety problem.

Blocking

None.

Major

  1. The docs say an early try never moves the end of the wait. It does, unless the wait is already at 24 h. Places: .github/scripts/fork-fleet-desk-seed.py:42-44 (header), :717 (TornLog: "it never moves the next try later"), :755 (trying: "so the step still ends when it would have"), .github/fork-fleet.md:924-926, fork-kit/desk/README.md:94-95. Why: an early try keeps last but raises tries, so left() now uses the doubled wait from the old last. I ran TornLog alone with a clock I set:

    • no early try: tries at h 0, 1, 3, 7, 15
    • early try at h 1.5: h 0, 1, 1.5, 5, 13 (main: 1.5, 6, 14)
    • early try at h 4.5: h 0, 1, 3, 4.5, 11 (main: 4.5, 13)

    So the early try at h 1.5 moves the next normal try from h 3 to h 5. Only once tries reaches 6 (the 24 h cap) does the end really stay put. The schedule itself is fine and bounded: it backs off, it is never later than main, it is capped at 24 h, and the PR body describes it correctly ("the next wait still doubles ... runs from the last try that waited"). The wrong part is the docs. Example: a host remade at h 1.5 and then fixed at h 1.6. The README says the fix waits for the end of that wait (h 3), but it is fetched at h 5.

    Fix: change the five lines to say "the next wait doubles but runs from the last try that waited, so an early try moves the next try at most one step later, never past 24 h". Also rename test_an_early_try_never_moves_the_next_try_later to something like ..._waits_from_the_last_try_that_waited. The other way out is to stop the early try from doubling the wait. That changes the hourly-remake schedule again, so I recommend the wording fix.

Minor

  1. .github/scripts/fork-fleet-desk-seed.py:425: in sparse_read, writing the probe tar (tarfile.open(... mode='w' ...) and addfile) is outside the try. If a later Python refuses to write a GNU.sparse.* pax header, run() raises at :658 before its try. The run then crashes (exit 1, not 2) and skips the age drop that the "fetches nothing" path promises. This is unlikely. Fix: move the write into the try, and add it to the "not known to be refused → counted as read" branch.
  2. :431: any Torn from the probe counts as "refused". A Torn from another of Info's limits (or from the new fromtarfile) on a later tarfile would hide a sparse read. Low risk, because the probe is tiny. Could check for 'sparse member' in str(e).
  3. PR body: on main the new tests give 9 failures and 2 errors on Linux Python 3.12 (all 7 tar-end subtests fail, not 5), not 7 and 2. Only the count is off; the claim that the tests fail on main holds.

State question

  • Runs again: after an early try, early is true. A second new copy in the same step waits (tested). Once the step ends, a normal try clears early. At most one early try between normal tries.
  • Killed half-way through a fetch or unpack: .torn.json is saved by trying() before the fetch, with last kept and tries + 1. The next run reads the step that was running, and clean() empties .new. The swap is still a rename after the trailer check, so a torn seed is never swapped in. The new zeros check runs inside the with, before p.wait and the trailer check, so a cut stream there is torn as before.
  • A record written by fork fleet: a desktop fetches its desk pool's seeds (D11b) #237 (early try moved last): read as it is, it waits from that last. The test passes on both main and this branch, as the body says. Records without early or copy behave as before.
  • Clock moved back: a last ahead of now gives left > wait, so it is tried now, not early, and last becomes now. An early try cannot happen with now < last. Same as before.
  • First run after upgrade: sparse_read() runs once per run, on 3 small in-memory tars. On this host (Python 3.12) it returns [].
  • Tar end: Info.fromtarfile also wraps the nested fromtarfile in _proc_pax and _proc_gnulong. So a pax header followed by end blocks becomes SubsequentHeaderError, then Torn, which is right. A stream of only end blocks still gives an empty seed. Reading the rest through t.fileobj covers tarfile's buffered bytes, and Summed still counts, hashes and caps them.

Tests (Linux, Python 3.12, run on this machine)

  • fork-fleet-desk-seed.test.py at 9660496: 75 tests OK.
  • The PR's 6 new and changed tests against main's script: 9 FAIL and 2 ERROR (only the old-record test passes, as intended).
  • Spot-checks: I removed each fix line alone and ran the 6 tests. Each went red:
    • last kept on an early try → hourly schedule test and early-try test
    • log hours from due (back to 2^(tries-1)) → hourly schedule test
    • fromtarfile turning header errors into Torn (re-raise instead) → all 7 tar-end subtests
    • zeros-only check after the end → the 2 "bytes after" subtests
    • sparse_read in run → all 3 sparse forms
    • override every _proc_gnusparse_* (back to the 3 fixed names) → _proc_gnusparse_11 test
  • Old-schedule test change ([0,1,2,6,7] → [0,1,2,5,6], log hours [1,2,3,8,15]): justified. It follows exactly from keeping last, and my manual trace gives the same hours.
  • CI on 9660496: all checks pass.

- Docs: an early try does move the next normal try one step later (the
  wait doubles from the last try that waited; only at the 24 h cap not).
  Five lines now say so; the early-try test is renamed to match and also
  checks the 24 h cap.
- sparse_read: the probe tar is made inside its try, so a tarfile that
  cannot write it gives exit 2 and old seeds are still dropped. Only the
  probe's own refusal counts as refused; another Torn, a tarfile error or a
  member read whole is named and fails closed. New probes: an old-GNU
  sparse member and a header over HEADER_MOST, which prove tarfile still
  calls Info._proc_member.
- The tar-end test also accepts the size -1 message of Python 3.13.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@scuttletoby

Copy link
Copy Markdown
Owner Author

Fix (head d666cd6) for lens A and lens B on 9660496

Changed

  • Lens B major, lens A minor 4 (wording). The five lines (script header, TornLog and trying docstrings, fork-fleet.md, the desk README) now say what the code does: an early try counts, so the next wait doubles, but the wait runs from the last try that waited, not from the early try. The next normal try comes at most one step later (h 5, not h 3, after an early try at h 1.5), and not at all at the 24 h cap. The test is renamed test_an_early_try_keeps_the_wait_running_from_the_last_try_that_waited. It checks the same schedule and now also checks that an early try at the 24 h cap moves nothing.
  • Lens B minor 2, lens A minor 2. The probe tar is now made inside the try. A tarfile that cannot write it is named, and the run exits 2 and still drops seeds past their age. New test: test_a_probe_that_cannot_be_made_still_drops_an_old_seed_and_is_exit_2. On the old script, the test gets a raw ValueError (exit 1).
  • Lens B minor 3, lens A minor 1. A probe now counts as refused only when its own refusal tears it. Another Torn, a tarfile error, or a member read whole is named, and the run fails closed (exit 2). New test: test_only_its_own_refusal_proves_a_probe, which fails on the old script.
  • Lens A minor 3. Two new probes run on every run: an old-GNU S member and a header over HEADER_MOST. Each must be torn by Info._proc_member, so a tarfile that stops calling it no longer fetches. Covered by the same test (its _proc_member case).
  • Lens B minor 4. The PR body now gives 9 failures and 2 errors on Linux. It also has a new "Review round" section.
  • Also: on Python 3.13.5 the tar-end test failed only on its message for a pax size of -1, because guarded tears it there (the seed was kept). The test now accepts that message too.

Tests: fork-fleet-desk-seed.test.py has 77 tests and passes on Linux with Python 3.12 and 3.13.5. On the old script, the new and changed tests give 6 failures and 1 error. The renamed early-try test passes on both scripts, because only its name and docs changed. Spot-check: with the own-refusal check removed, test_only_its_own_refusal_proves_a_probe goes red. fork-owned-reads.test.py passes, and so does fork-seam-check.cjs. I did not run fork-gate-trust-docs.test.py locally, because a local guard blocks it; CI runs it.

Left, with why

@scuttletoby
scuttletoby merged commit 563db51 into main Nov 21, 2026
30 checks passed
scuttletoby added a commit that referenced this pull request Nov 21, 2026
* fork fleet: desk seed fetch round-5 nits (#258)

- An early try (a new copy on the host during a back-off wait) keeps `last`:
  it still counts, but never moves the end of the wait; the log line says
  the real time left.
- Every `_proc_gnusparse_*` handler of this Python's tarfile is refused, and
  each run reads a small sparse tar of each pax form (0.0, 0.1, 1.0) to prove
  tarfile still reaches the refusal; if not, it fetches nothing (exit 2).
- Only a block of zeros ends the tar (any other bad header tears the seed),
  and only zeros may follow it, read through tarfile's own buffer.
- Docs: a fix made right after another new copy waits for the step (up to
  24 h); the early-try rule; the tar end; the sparse check.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* fork fleet: desk seed fetch, fixes from the #729 reviews (#258)

- Docs: an early try does move the next normal try one step later (the
  wait doubles from the last try that waited; only at the 24 h cap not).
  Five lines now say so; the early-try test is renamed to match and also
  checks the 24 h cap.
- sparse_read: the probe tar is made inside its try, so a tarfile that
  cannot write it gives exit 2 and old seeds are still dropped. Only the
  probe's own refusal counts as refused; another Torn, a tarfile error or a
  member read whole is named and fails closed. New probes: an old-GNU
  sparse member and a header over HEADER_MOST, which prove tarfile still
  calls Info._proc_member.
- The tar-end test also accepts the size -1 message of Python 3.13.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
scuttletoby added a commit that referenced this pull request Nov 21, 2026
* fork fleet: desk seed fetch round-5 nits (#258)

- An early try (a new copy on the host during a back-off wait) keeps `last`:
  it still counts, but never moves the end of the wait; the log line says
  the real time left.
- Every `_proc_gnusparse_*` handler of this Python's tarfile is refused, and
  each run reads a small sparse tar of each pax form (0.0, 0.1, 1.0) to prove
  tarfile still reaches the refusal; if not, it fetches nothing (exit 2).
- Only a block of zeros ends the tar (any other bad header tears the seed),
  and only zeros may follow it, read through tarfile's own buffer.
- Docs: a fix made right after another new copy waits for the step (up to
  24 h); the early-try rule; the tar end; the sparse check.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* fork fleet: desk seed fetch, fixes from the #729 reviews (#258)

- Docs: an early try does move the next normal try one step later (the
  wait doubles from the last try that waited; only at the 24 h cap not).
  Five lines now say so; the early-try test is renamed to match and also
  checks the 24 h cap.
- sparse_read: the probe tar is made inside its try, so a tarfile that
  cannot write it gives exit 2 and old seeds are still dropped. Only the
  probe's own refusal counts as refused; another Torn, a tarfile error or a
  member read whole is named and fails closed. New probes: an old-GNU
  sparse member and a header over HEADER_MOST, which prove tarfile still
  calls Info._proc_member.
- The tar-end test also accepts the size -1 message of Python 3.13.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
scuttletoby added a commit that referenced this pull request Nov 21, 2026
* fork fleet: desk seed fetch round-5 nits (#258)

- An early try (a new copy on the host during a back-off wait) keeps `last`:
  it still counts, but never moves the end of the wait; the log line says
  the real time left.
- Every `_proc_gnusparse_*` handler of this Python's tarfile is refused, and
  each run reads a small sparse tar of each pax form (0.0, 0.1, 1.0) to prove
  tarfile still reaches the refusal; if not, it fetches nothing (exit 2).
- Only a block of zeros ends the tar (any other bad header tears the seed),
  and only zeros may follow it, read through tarfile's own buffer.
- Docs: a fix made right after another new copy waits for the step (up to
  24 h); the early-try rule; the tar end; the sparse check.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* fork fleet: desk seed fetch, fixes from the #729 reviews (#258)

- Docs: an early try does move the next normal try one step later (the
  wait doubles from the last try that waited; only at the 24 h cap not).
  Five lines now say so; the early-try test is renamed to match and also
  checks the 24 h cap.
- sparse_read: the probe tar is made inside its try, so a tarfile that
  cannot write it gives exit 2 and old seeds are still dropped. Only the
  probe's own refusal counts as refused; another Torn, a tarfile error or a
  member read whole is named and fails closed. New probes: an old-GNU
  sparse member and a header over HEADER_MOST, which prove tarfile still
  calls Info._proc_member.
- The tar-end test also accepts the size -1 message of Python 3.13.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Desk seed fetch (#237): round-5 lens nits

1 participant